#Makefile for ISBA soil model source files

include ../../mkfls_profs/Makefile.in
#include ./MakefileCheb.in
#include ./MakefileCheb_precise.in
#include MakefileBG.in

objfiles = \
 $(objfile_path)/solonoi_sub.o \
 $(objfile_path)/solonoii_mpi_sub.o \
 $(objfile_path)/ydifus_sub.o \
 $(objfile_path)/ydrov_sub.o \
 $(objfile_path)/chstar_func.o \
 $(objfile_path)/cmstar_func.o \
 $(objfile_path)/ph_func.o \
 $(objfile_path)/pm_func.o \
 $(objfile_path)/dqsat_func.o

 all : $(objfiles)


# Compiling other source files
 $(objfile_path)/%.o : %.f90 
	$(f90comp) $(opt_keys) $(check_keys) $(include_keys) $(formfree_key) $(keys) $< -o $@

 $(objfile_path)/%.o : %.f
	$(f90comp) $(opt_keys) $(check_keys) $(include_keys) $(formfixed_key) $(keys) $< -o $@


# Cleaning *.o and *.mod files
 clean : 
	rm -f $(objfiles)
